package button2;

import java.awt.event.ActionEvent;
import java.awt.event.ActionListener;
import javax.swing.JOptionPane;

public class PiortierUniwersalny implements ActionListener{
    private String imie;
    private int zadanie;
    
    public PiortierUniwersalny(){
        this.zadanie = 0;
        this.imie = "nie mam imienia";
    }
    public PiortierUniwersalny(String imie){
        this.zadanie = 0;
        this.imie = imie;
    }

    @Override
    public void actionPerformed(ActionEvent e) {
        if (e.getActionCommand() == "1") {
            zadanie1();
        }
        if (e.getActionCommand() == "2") {
            zadanie2();
        }
        if (e.getActionCommand() == "3") {
            zadanie3();
        }
        if (e.getActionCommand() == "4") {
            zadanie4();
        }
        if (e.getActionCommand() == "5") {
            zadanie5();
        }
    }   
    
    private void zadanie1(){
        JOptionPane.showMessageDialog(null, "zadanie 1");
    }
    
    private void zadanie2(){
        JOptionPane.showMessageDialog(null, "zadanie 2");
    }
    
    private void zadanie3(){
        JOptionPane.showMessageDialog(null, "zadanie 3");
    }
    
    private void zadanie4(){
        JOptionPane.showMessageDialog(null, "zadanie 4");
    }
    
    private void zadanie5(){
        JOptionPane.showMessageDialog(null, "zadanie 5");
    }
    
}
